# eric7.Preferences.ConfigurationPages.DebuggerGeneralPage

Module implementing the Debugger General configuration page.

### Global Attributes

None

### Classes

DebuggerGeneralPage | Class implementing the Debugger General configuration page.
PreviewModel | Class to show an example of the selected background colours for the debug viewer.

### Functions

create | Module function to create the configuration page.

## DebuggerGeneralPage

Class implementing the Debugger General configuration page.

### Derived from

ConfigurationPageBase, Ui_DebuggerGeneralPage

### Class Attributes

None

### Class Methods

None

### Methods

DebuggerGeneralPage | Constructor
on_addAllowedHostButton_clicked | Private slot called to add a new allowed host.
on_allowedHostsList_currentItemChanged | Private method to set the state of the edit and delete button.
on_deleteAllowedHostButton_clicked | Private slot called to delete an allowed host.
on_editAllowedHostButton_clicked | Private slot called to edit an allowed host.
on_interfaceSelectorComboBox_currentIndexChanged | Private slot to handle the selection of a network interface type.
on_passiveDbgGroup_toggled | Private slot to handle a change of the checked state of the passive debugging option.
on_remoteDebuggerGroup_toggled | Private slot to handle a change of the checked state of the remote debugging option.
save | Public slot to save the Debugger General (1) configuration.

### Static Methods

None

#### DebuggerGeneralPage (Constructor)

DebuggerGeneralPage()

Constructor

#### DebuggerGeneralPage.on_addAllowedHostButton_clicked

on_addAllowedHostButton_clicked()

Private slot called to add a new allowed host.

#### DebuggerGeneralPage.on_allowedHostsList_currentItemChanged

on_allowedHostsList_currentItemChanged(current, _previous)

Private method to set the state of the edit and delete button.

current (QListWidgetItem)
  new current item
_previous (QListWidgetItem)
  previous current item (unused)

#### DebuggerGeneralPage.on_deleteAllowedHostButton_clicked

on_deleteAllowedHostButton_clicked()

Private slot called to delete an allowed host.

#### DebuggerGeneralPage.on_editAllowedHostButton_clicked

on_editAllowedHostButton_clicked()

Private slot called to edit an allowed host.

#### DebuggerGeneralPage.on_interfaceSelectorComboBox_currentIndexChanged

on_interfaceSelectorComboBox_currentIndexChanged(index)

Private slot to handle the selection of a network interface type.

index (int)
  index of the selected entry

#### DebuggerGeneralPage.on_passiveDbgGroup_toggled

on_passiveDbgGroup_toggled(checked)

Private slot to handle a change of the checked state of the passive debugging option.

checked (bool)
  checked state

#### DebuggerGeneralPage.on_remoteDebuggerGroup_toggled

on_remoteDebuggerGroup_toggled(checked)

Private slot to handle a change of the checked state of the remote debugging option.

checked (bool)
  checked state

#### DebuggerGeneralPage.save

save()

Public slot to save the Debugger General (1) configuration.

Up

## PreviewModel

Class to show an example of the selected background colours for the debug viewer.

### Derived from

QAbstractItemModel

### Class Attributes

None

### Class Methods

None

### Methods

PreviewModel | Constructor
columnCount | Public Qt slot to get the column count.
data | Public Qt slot get the role data of item.
flags | Public Qt slot to get the item flags.
index | Public Qt slot to get the index of item at row:column of parent.
parent | Public Qt slot to get the parent of the given child.
rowCount | Public Qt slot to get the row count.
setColor | Public slot to update the background colour indexed by key.

### Static Methods

None

#### PreviewModel (Constructor)

PreviewModel()

Constructor

#### PreviewModel.columnCount

columnCount(parent=None)

Public Qt slot to get the column count.

parent (QModelIndex (optional))
  the model parent (defaults to None) (unused)

Return:
  number of columns

Return Type:
  int

#### PreviewModel.data

data(index, role=Qt.ItemDataRole.DisplayRole)

Public Qt slot get the role data of item.

index (QModelIndex)
  the model index
role (QtCore.Qt.ItemDataRole)
  the requested data role

Return:
  role data of item

Return Type:
  str, QBrush or None

#### PreviewModel.flags

flags(_index)

Public Qt slot to get the item flags.

_index (QModelIndex)
  of item (unused)

Return:
  item flags

Return Type:
  QtCore.Qt.ItemFlag

#### PreviewModel.index

index(row, column, parent=None)

Public Qt slot to get the index of item at row:column of parent.

row (int)
  number of rows
column (int)
  number of columns
parent (QModelIndex (optional))
  the model parent (defaults to None)

Return:
  new model index for child

Return Type:
  QModelIndex

#### PreviewModel.parent

parent(_child)

Public Qt slot to get the parent of the given child.

_child (QModelIndex)
  the model child node (unused)

Return:
  new model index for parent

Return Type:
  QModelIndex

#### PreviewModel.rowCount

rowCount(parent=None)

Public Qt slot to get the row count.

parent (QModelIndex (optional))
  the model parent (defaults to None) (unused)

Return:
  number of rows

Return Type:
  int

#### PreviewModel.setColor

setColor(key, bgcolour)

Public slot to update the background colour indexed by key.

key (str)
  the name of background
bgcolour (QColor)
  the new background colour

Up

## create

create(_dlg)

Module function to create the configuration page.

_dlg (ConfigurationDialog)
  reference to the configuration dialog (unused)

Return:
  reference to the instantiated page

Return Type:
  ConfigurationPageBase

Up